package com.aaa.dang.modules.mobilereview.controller;

import com.aaa.dang.common.util.ResultModel;
import com.aaa.dang.modules.mobilereview.service.IMobileReviewService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.CrossOrigin;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestParam;
import org.springframework.web.bind.annotation.RestController;

import java.util.Map;

/**
 * @Author: ymk
 * @Date: 2018/12/27 11:12
 * @description:
 */
@RestController
@CrossOrigin
@RequestMapping("/mobilereview")
public class MobileReviewController  {

    @Autowired
    private IMobileReviewService ser;

    /**
     * 入住申请
     * @param query
     * @return
     */
    @RequestMapping("/liveApply")
    public ResultModel liveApply(@RequestParam Map<String,Object> query){
        System.out.println(query);
        return ser.liveApply(query);
    }

    /**
     * 退宿申请
     * @param query
     * @return
     */
    @RequestMapping("/retireApply")
    public ResultModel retireApply(@RequestParam Map<String,Object> query){
        return ser.retireApply(query);

    }
}
